# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=ipsourcebypass
pkgver=1.2.r17.gd89edb1
pkgrel=1
pkgdesc='This Python script can be used to bypass IP source restrictions using HTTP headers.'
groups=('blackarch' 'blackarch-webapp')
arch=('any')
url='https://github.com/p0dalirius/ipsourcebypass'
license=('custom:unknown')
depends=('python' 'python-requests' 'python-rich')
makedepends=('git')
source=("git+https://github.com/p0dalirius/$pkgname.git")
sha512sums=('SKIP')

pkgver() {
  cd $pkgname

  git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}

package() {
  cd $pkgname

  install -Dm 755 "$pkgname.py" "$pkgdir/usr/bin/$pkgname"
  install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README.md
}

